package com.example.backend.dto;

import com.example.backend.domain.enums.NotificationChannel;
import com.example.backend.domain.enums.NotificationPriority;
import com.example.backend.domain.enums.NotificationType;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import lombok.Data;

import java.time.Instant;
import java.util.Map;

/**
 * 发送通知请求DTO
 */
@Data
public class SendNotificationRequest {
    
    @NotNull(message = "用户ID不能为空")
    private Long userId;
    
    @NotBlank(message = "通知标题不能为空")
    @Size(max = 100, message = "通知标题长度不能超过100个字符")
    private String title;
    
    @NotBlank(message = "通知内容不能为空")
    @Size(max = 1000, message = "通知内容长度不能超过1000个字符")
    private String content;
    
    @NotNull(message = "通知类型不能为空")
    private NotificationType type;
    
    @NotNull(message = "通知通道不能为空")
    private NotificationChannel channel;
    
    private NotificationPriority priority = NotificationPriority.NORMAL;
    
    private String actionUrl;
    
    private Map<String, Object> metadata;
    
    private Instant scheduledAt;
}
